/* Reset some default styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Arial, sans-serif;
    background-color: #f2f2f2;
    margin: 0;
    padding-top: 0px;
    /* Add space for the fixed header */
}

/* Header Styles */
.header {
    /* position: fixed;
    top: 0; */
    left: 0;
    right: 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: #333;
    color: white;
    padding: 15px;
    z-index: 1000;
    /* Ensure the header is above other content */
}

.category-buttons {
    display: flex;
    align-items: center;
}

.category-button {
    background-color: transparent;
    border: none;
    color: white;
    margin: 10px;
    cursor: pointer;
}

.category-button>a {
    text-decoration: none;
    color: inherit;
}

/* Product card container */
.product-cards-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    margin: 10px 20px 10px 20px;
    /* Adjust top margin for card alignment */
}

/* Product card */
.product-card {
    background-color: #fff;
    border-radius: 10px;
    box-shadow: 0px 0px 10px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    flex-basis: calc(50% - 20px);
    /* Set width to occupy 50% minus margin for two cards per row */
    margin-bottom: 20px;
    /* Add space between rows */
    display: flex;
    /* Make the container a flex container */
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    height: 250px;
}

/* Product card hover effect */
.product-card:hover {
    transform: scale(1.05);
    box-shadow: 0px 0px 20px rgba(0, 0, 0, 0.2);
}

/* Product image on the left */
.product-image {
    max-width: 100%;
    height: auto;
    flex: 1;
    /* Take up 50% of the container */
}

/* Product details on the right */
.product-details {
    flex: 1;
    /* Take up 50% of the container */
    padding: 20px;
    max-height: 250px;
    /* Set a maximum height for the product details */
    overflow-y: auto;
    /* Add vertical scroll when the content exceeds the max height */
}

.product-title {
    font-size: 1.5rem;
    font-weight: bold;
    margin-bottom: 10px;
}

.product-description {
    font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
    ;
    font-size: 1rem;
    color: #555;
    margin-bottom: 10px;
}

.product-price {
    font-size: 1.25rem;
    color: #ff6600;
    font-weight: bold;
}

/* Add a class for the enlarged image */
.enlarged-image {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 2000;
    /* Ensure the enlarged image is above other content */
}

.enlarged-image img {
    max-width: 100%;
    height: auto;
    max-height: 80vh;
    /* Set a maximum height for the enlarged image */
}

/* Close button styles */
.close-button {
    position: absolute;
    top: 20px;
    right: 20px;
    color: white;
    cursor: pointer;
    font-size: 20px;
}

/* Center-align the search div */
.search-div {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    padding: 10px;
    background-color: #333;
    color: white;
}

.search-input {
    padding: 4px 50px;
}

.category-button.category-button:hover {
    color: #ee7b11;
}

.category-button.category-button:focus {
    color: #ee7b11;
}

/* Responsive design */
@media (max-width: 768px) {

    /* Center the search div on smaller screens */
    .search-div {
        flex-direction: column;
    }

    .footer {
        padding-left: 0 !important;
    }

    .header {
        flex-direction: column-reverse;
        padding: 0px;
    }

    .search-input {
        margin-top: 10px;
        width: 100%;
        padding: 4px 40px;
    }

    /* Center category buttons on smaller screens */
    .category-buttons {
        flex-direction: row;
        align-items: center;
        margin-top: 0px;
    }

    .category-button {
        margin-bottom: 10px;
    }

    /* Reset the flex layout for product cards in mobile view */
    .product-card {
        flex-direction: column;
        padding-top: 20px;
        /* Add padding to the top of product cards in mobile view */
        padding-left: 10px;
        padding-right: 10px;
        height: 500px;
    }

    /* Display only one product card per row in mobile view */
    .product-card {
        flex-basis: 100%;
        /* One card per row */
    }

    /* Style the product image in mobile view */
    .product-image {
        order: 0;
        /* Reset the order to default */
        max-width: 100%;
        /* Allow the image to take full width */
        margin: 0 auto 10px;
        /* Center-align the image horizontally and add some bottom margin for spacing */
        width: 90%;
    }

    /* Style the product description in mobile view */
    .product-details {
        padding: 10px;
        /* Add some padding for spacing */
        text-align: center;
        /* Center-align the description */
    }

    /* Style the product title in mobile view */
    .product-title {
        font-size: 1.25rem;
        /* Reduce font size */
        margin-top: 10px;
        /* Add some top margin for spacing */
    }

    /* Style the product description in the modified structure for mobile view */
    .product-description {
        font-size: 1rem;
        /* Reduce font size */
        margin-top: 10px;
        /* Add some top margin for spacing */
    }
}